<?php
/*******************************************************************************
 * $Date:: Oct 10, 2009 1:38:34 AM											   $
 * $Revision:																   $
 * $Author:: Tuan Duong													   	   $
 * $Comment::															   	   $
 ******************************************************************************/

class Bet_Bean_Menu {
	public $text = "";
	public $link = "#";
	public $class = "";
	public $submenu = false;
	
	public function __construct($text = "", $link = "", $class = "") {
		$this->text = $text;
		$this->link = $link;
		$this->class = $class; 
	}
	
	public function bindNode($node) {
		$xmlUtil = new Bet_Util_Xml();
		$this->text = $xmlUtil->getNodeValueByNodeName("text", $node);
		$this->link = str_replace("__", "&", $xmlUtil->getNodeValueByNodeName("link", $node));
		$this->class = $xmlUtil->getNodeAtributeByNodeName("link", "class", $node);
	}
}